import EventRoute from "./EventRoute"
import SystemLoyaltyService from "../service/SystemLoyaltyService";

const routes = new Array();
const systemLoyaltyService = new SystemLoyaltyService();
/**
 * 积分详情
 */
routes.push(
    new EventRoute('app-loyalty-detail', 'event', async (api, data = {}) => {
        systemLoyaltyService.get(data.data)
    })
)

/**
 * 加积分
 */
routes.push(
    new EventRoute('app-loyalty-add', 'event', async (api, data = {}) => {
        systemLoyaltyService.add(data.data)
    })
)

/**
 * 减积分
 */
routes.push(
    new EventRoute('app-loyalty-sub', 'event', async (api, data = {}) => {
        systemLoyaltyService.sub(data.data)
    })
)

export default routes;
